/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package htmlextract;

import java.io.*;
import java.net.URL;
import java.net.URLConnection;
import javax.swing.text.html.parser.ParserDelegator;

/**
 *
 * @author Fidschi
 */
public class Main {

    public static void main(String [] args) throws Exception
    {
        Callback  callback = new Callback();
        URL url = new URL("http://www.fh-deggendorf.de/bwl/topaktuell/verschiebungen/changes/vvs_bwl1_as.html");
        URLConnection connection = url.openConnection();
        InputStream is = connection.getInputStream();
        InputStreamReader isr = new InputStreamReader(is);
        BufferedReader br = new BufferedReader(isr);
        ParserDelegator delegator = new ParserDelegator();
        delegator.parse(br, callback, true);
        InfoExtractor infExt = new InfoExtractor();
        infExt.setVvs(callback.getBuf());
        infExt.getInfo();
    }

}
